package com.xaicode.auth.mapper;

import com.xaicode.auth.base.BaseMapper;
import com.xaicode.auth.constant.DatasourceName;
import com.xaicode.auth.entity.SysDept;
import com.baomidou.dynamic.datasource.annotation.DS;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
@DS(DatasourceName.CCM)
public interface SysDeptMapper extends BaseMapper<SysDept> {

    /**
     * 根据部门ID查询角色和部门关联的数量
     */
    int selectRoleDeptCountByDeptIds(@Param("deptIds") List<Integer> deptIds);

}
